//--------------------------------------------------------------------------
// 
//  Copyright (c) Chili Software.  All rights reserved. 
// 
//  File: OEField.cs
//
//  Description: Field for the ObjectExpression.
// 
//--------------------------------------------------------------------------

using System;

namespace Chili.Opf3.Query.OPathParser
{
	/// <summary>
	/// Represents a storage field in the OPath statement. 
	/// </summary>
	/// <remarks>
	/// Storage fields are encapsulated by this class. They are used in the internally created insert,
	/// update, delete commands and for the additional fields of the 
	/// <see cref="IDynamicExtensible">IDynamicExtensible</see> interface.
	/// </remarks>
	[Serializable]
	public sealed class OEField : OEItem
	{
		private string _name;

		/// <summary>
		/// Creates a new instance of the <see cref="OEField">OEField Class</see>.
		/// </summary>
		/// <param name="name">Specifies the name of the field.</param>
		internal OEField(string name)
		{
			_name = name;
		}

		/// <summary>
		/// Returns the name of the field.
		/// </summary>
		public string Name
		{
			get { return _name; }
		}
	}
}
